<?php
$recent_listing_car = $this->listing_model->get_listings('CAR', false,51,10, 0);
$recent_requirement_car = $this->requirement_model->get_requirements('CAR', 51, 10, 0,'DESC')
?>
<div class="box_R1" style="float:left; padding-bottom:0px; margin-bottom:0px">
    <div class="title reg bold"> 
        <a href="#" class="detail_search inline-block align_right fright">See all</a> 
        <span class="inline-block fleft align_left"><h3> Recent Requirments</h3></span>
        <div class="clear"></div>
    </div>
    <div class="clear"> </div>
    <div id="inner" style="line-height:12px">
        <ul>
            <?php foreach ($recent_requirement_car as $recent_requirement_car): ?> 
                <li>
                    <p>
                    <div class="fright font_2">Rs.  <?= moneyFormat($recent_requirement_car->price); ?> </div>  
                    <div class="bold color_2" style="line-height:13px">
                        <a href="<?= base_url();?>view/requirement/<?= url_title($this->management_model->get_version('CAR', $recent_requirement_car->version)->version, '-', true); ?>/<?= $recent_requirement_car->id;?>"> <?= $this->management_model->get_version('CAR', $recent_requirement_car->version)->version; ?></a>
                    </div>
                    <div class="font_1"> 
                        <?= $this->location_model->get_city_name($recent_requirement_car->city); ?>, 
                        <?= $this->location_model->get_state_name($recent_requirement_car->state); ?>
                    </div> 
                    </p>
                </li>
            <?php endforeach; ?>
        </ul>

    </div>
</div> <!-- End of Box_2 -->

<div class="box_R1" style="float:right; padding-bottom:0px; margin-bottom:0px">
    <div class="title reg bold"> 
        <a href="#" class="detail_search inline-block align_right fright" > See all </a> 
        <span class="inline-block fleft align_left"><h3> Recent Listings</h3></span>
        <div class="clear"></div>
    </div>
    <div class="clear"> </div>
    <div id="inner" style="text-align: justify">
        <ul>
            <?php foreach ($recent_listing_car as $recent_listing_car): ?> 
                <li>
                    <p>
                    <div class="fright font_2">Rs.  <?= moneyFormat($recent_listing_car->price); ?> </div>
                    <div class="bold color_2" style="line-height:13px">
                        <a href="<?= base_url();?>view/detail/<?= strtolower(url_title($this->management_model->get_version('CAR', $recent_listing_car->version)->version)); ?>/<?= $recent_listing_car->id; ?>"> <?= $this->management_model->get_version('CAR', $recent_listing_car->version)->version; ?> </a>
                    </div>
                    <div class="font_1"> 
                        <?= $this->location_model->get_city_name($recent_listing_car->city); ?>, 
                        <?= $this->location_model->get_state_name($recent_listing_car->state); ?>
                    </div> 
                    </p>
                </li>
            <?php endforeach; ?>

        </ul>

    </div>

</div> <!-- End of Box_2 -->
